package com.ruoyi.ob.service.impl;

import com.ruoyi.ob.domain.PurchaseReport;
import com.ruoyi.ob.mapper.PurchaseReportMapper;
import com.ruoyi.ob.service.PurchaseReportService;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;
import java.util.Map;

@Service
public class PurchaseReportServiceImpl implements PurchaseReportService {

    @Autowired
    private PurchaseReportMapper purchaseReportMapper;

    @Override
    public List<PurchaseReport> getQuantitySummaryByGoods(Map<String, Object> params) {
        return purchaseReportMapper.getQuantitySummaryByGoods(params);
    }

    @Override
    public List<PurchaseReport> getAmountSummaryBySupplier() {
        return purchaseReportMapper.getAmountSummaryBySupplier();
    }

    @Override
    public List<PurchaseReport> getPurchaseTrend(Map<String, Object> params) {
        return purchaseReportMapper.getPurchaseTrend(params);
    }

    @Override
    public Map<String, Object> getStatistics() {
        return purchaseReportMapper.getStatistics();
    }

    @Override
    public List<PurchaseReport> getRecentOrders() {
        return purchaseReportMapper.getRecentOrders();
    }
}